package com.atguigu.day03;

import sun.font.DelegatingShape;

import java.util.Scanner;

public class Test4 {

    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        System.out.print("请输入月份:");
        int month = s.nextInt();
        System.out.print("请输入日期:");
        int day = s.nextInt();
        String ans = "水瓶";
        if (month == 3 && day >= 21 || month == 4 && day <= 19)
            ans = "白羊";
        else if (month == 4 && day >= 20 || month == 5 && day <= 20)
            ans = "金牛";
        else if (month == 5 && day >= 21 || month == 6 && day <= 21)
            ans = "双子";
        else if (month == 6 && day >= 22 || month == 7 && day <= 22)
            ans = "巨蟹";
        else if (month == 7 && day >= 23 || month == 8 && day <= 22)
            ans = "狮子";
        else if (month == 8 && day >= 23 || month == 9 && day <= 22)
            ans = "处女";
        else if (month == 9 && day >= 23 || month == 10 && day <= 23)
            ans = "天秤";
        else if (month == 10 && day >= 24 || month == 11 && day <= 22)
            ans = "天蝎";
        else if (month == 11 && day >= 23 || month == 12 && day <= 21)
            ans = "射手";
        else if (month == 12 && day >= 22 || month == 1 && day <= 19)
            ans = "摩羯";
        else if (month == 1 && day >= 20 || month == 2 && day <= 18)
            ans = "水瓶";
        else if (month == 2 && day >= 19 || month == 3 && day <= 20)
            ans = "双鱼";
//        for (month=1;month<13;month++){
//        for(day=1;day<30;day++) {
//            int sco = month * 30 + day;
//            String ans = "水瓶";
//            if (sco >= 111 && sco <= 139)
//                ans = "白羊";
//            else if (sco >= 140 && sco <= 170)
//                ans = "金牛";
//            else if (sco >= 171 && sco <= 201)
//                ans = "双子";
//            else if (sco >= 202 && sco <= 232)
//                ans = "巨蟹";
//            else if (sco >= 233 && sco <= 262)
//                ans = "狮子";
//            else if (sco >= 263 && sco <= 292)
//                ans = "处女";
//            else if (sco >= 293 && sco <= 323)
//                ans = "天秤";
//            else if (sco >= 324 && sco <= 352)
//                ans = "天蝎";
//            else if (sco >= 353 && sco <= 381)
//                ans = "射手";
////        else if (sco>=382)
////            ans = "摩羯";
//            else if (sco >= 50 && sco <= 78)
//                ans = "水瓶";
//            else if (sco >= 79 && sco <= 110)
//                ans = "双鱼";
//            else
//                ans = "摩羯";
        System.out.print("生日" + month + "月" + day + "日是" + ans + "座 ");
    }
}
